import request from "./request";
export const LoginApi = (params: ILoginParams): SRP<string> =>
  request.post("/1024/login", params);

// export const RegisterApi = (): Promise<IServerResponse<null>> =>
//   request.post("/aaa");

export const getHomeDataApi = (): SRP<IHomeData> => request.get("/6666");

// 根据actioncode 得到题目分类的接口
export const getQuestionTypeByActionCodeApi = (
  actionCode: string
): SRP<IQuetionType[]> => request.get(`/1314/${actionCode}/all`);

// 获取题目列表
export const getQuestionListApi = (
  params: IQuetionListParams
): SRP<IQuestionType[]> => request.post("/1314", params);

export const getSubjectsApi = (): SRP<ISubject[]> => request.get("/6666/field");
